// 监督质量
export const sex = [
	{text:'男',value:'0'},
	{text:'女',value:'1'},
	{text:'未知',value:'2'}
]
//文化程度
export const eduLevel = [
	{text:'小学',value:'01'},
	{text:'初中',value:'02'},
	{text:'高中',value:'03'},
	{text:'中专',value:'04'},
	{text:'大专',value:'05'},
	{text:'本科',value:'06'},
	{text:'硕士',value:'07'},
	{text:'博士',value:'08'},
	{text:'其他',value:'99'}
]
//政治面貌
export const political = [
	{text:'中共党员',value:'01'},
	{text:'中共预备党员',value:'02'},
	{text:'共青团员',value:'03'},
	{text:'民革党员',value:'04'},
	{text:'民盟盟员',value:'05'},
	{text:'民建会员',value:'06'},
	{text:'民进会员',value:'07'},
	{text:'农工党党员',value:'08'},
	{text:'致公党党员',value:'09'},
	{text:'九三学社社员',value:'10'},
	{text:'台盟盟员',value:'11'},
	{text:'无党派民主人士',value:'12'},
	{text:'群众',value:'13'}
]
//整改状态
export const rectification_status = [
	{text:'未整改',value:'0'},
	{text:'待审核',value:'1'},
	{text:'已整改',value:'2'},
	{text:'未通过',value:'3'}
]
//整改类型
export const enterprise_rectification_type = [
	{text:'监督抽查',value:'1'},
	{text:'动态抽查',value:'2'},
]
//项目状态
export const project_status = [
	{text:'申报中',value:'0'},
	{text:'在建',value:'1'},
	{text:'未开工',value:'2'},
	{text:'停工',value:'3'},
	{text:'完工(终止安全监督)',value:'5'},
	{text:'竣工',value:'7'},
	{text:'特殊',value:'8'},
]

//单位类型
export const unit_type = [
	{text:'建设单位',value:'SG'},
	{text:'建设企业',value:'JS'},
	{text:'勘察企业',value:'KC'},
	{text:'监理企业',value:'JL'},
	{text:'设计企业',value:'SJ'},
	{text:'安拆企业',value:'AC'},
	{text:'爬架企业',value:'PJ'},
	{text:'租赁企业',value:'ZL'},
	{text:'检测企业',value:'JC'},
]

//婚姻状态
export const marital_status = [
	{text:'未婚',value:'01'},
	{text:'已婚',value:'02'},
	{text:'离异',value:'03'},
	{text:'丧偶',value:'04'},
]

//民族
export const nation_list = [
	{text:'汉族',value:'01'},
	{text:'壮族',value:'02'},
	{text:'满族',value:'03'},
	{text:'回族',value:'04'},
	{text:'苗族',value:'05'},
	{text:'维吾尔族',value:'06'},
	{text:'土家族',value:'07'},
	{text:'彝族',value:'08'},
	{text:'蒙古族',value:'09'},
	{text:'藏族',value:'10'},
	{text:'布依族',value:'11'},
	{text:'侗族',value:'12'},
	{text:'瑶族',value:'13'},
	{text:'朝鲜族',value:'14'},
	{text:'白族',value:'15'},
	{text:'哈尼族',value:'16'},
	{text:'哈萨克族',value:'17'},
	{text:'黎族',value:'18'},
	{text:'傣族',value:'19'},
	{text:'畲族',value:'20'},
	{text:'傈僳族',value:'21'},
	{text:'仡佬族',value:'22'},
	{text:'东乡族',value:'23'},
	{text:'高山族',value:'24'},
	{text:'拉祜族',value:'25'},
	{text:'水族',value:'26'},
	{text:'佤族',value:'27'},
	{text:'纳西族',value:'28'},
	{text:'羌族',value:'29'},
	{text:'土族',value:'30'},
	{text:'仫佬族',value:'31'},
	{text:'锡伯族',value:'32'},
	{text:'柯尔克孜族',value:'33'},
	{text:'达斡尔族',value:'34'},
	{text:'景颇族',value:'35'},
	{text:'毛南族',value:'36'},
	{text:'撒拉族',value:'37'},
	{text:'塔吉克族',value:'38'},
	{text:'阿昌族',value:'39'},
	{text:'普米族',value:'40'},
	{text:'鄂温克族',value:'41'},
	{text:'怒族',value:'42'},
	{text:'京族',value:'43'},
	{text:'基诺族',value:'44'},
	{text:'德昂族',value:'45'},
	{text:'保安族',value:'46'},
	{text:'俄罗斯族',value:'47'},
	{text:'裕固族',value:'48'},  
	{text:'塔塔尔族',value:'49'}, 
	{text:'乌孜别克族',value:'50'},
	{text:'门巴族',value:'51'},     
	{text:'鄂伦春族',value:'52'},
	{text:'独龙族',value:'53'},
	{text:'赫哲族',value:'54'},
	{text:'珞巴族',value:'55'},
	{text:'布朗族',value:'56'},
]


//是否有重大疾病史
export const is_major_disease = [
	{text:'是',value:'1'},
	{text:'否',value:'0'},
]

//键值处理
export function dictLabel(data, value) {
  let str = '--'
  if(data?.length&&value!==null&&value!==undefined&&value!==''){
	  let index = data.map(item=>item.value).indexOf(value.toString())
	  if(index>=0){
		  str = data[index].text||data[index].label || '--'
	  } else {
		  str = value
	  }
  }
  return str;
}


